package doan.chuyennganh.base;

import android.app.Application;
import android.os.Build;
import android.os.StrictMode;

public class DoAnApplication  extends Application implements IRequestQueue{
	private RequestQueue mRequestQueue = null;
	public static String uuid = "";
	@SuppressWarnings("unused")
	@Override
	public void onCreate() {
		if (Config.DEVELOPER_MODE && Build.VERSION.SDK_INT >= Build.VERSION_CODES.GINGERBREAD) {
			StrictMode.setThreadPolicy(new StrictMode.ThreadPolicy.Builder().detectAll().penaltyDialog().build());
			StrictMode.setVmPolicy(new StrictMode.VmPolicy.Builder().detectAll().penaltyDeath().build());
		}

		super.onCreate();
		
	}

	public static class Config {
		public static final boolean DEVELOPER_MODE = false;
	}
	
	@Override
	public RequestQueue getRequestQueue() {
		if (mRequestQueue == null) {
			mRequestQueue = new RequestQueue();
		}
		return mRequestQueue;
	}
	
}
